import {createRouter, createWebHistory} from 'vue-router'


const routes = [


    {
        path: '/',
        redirect: to => {
            return {
                path: '/home',
                name: 'Home',
                component: () => import('../views/Home.vue')
            }
        }

    },
    {
        path: '/home',
        name: 'Home',
        component: () => import('../views/Home.vue')

    },
    {
        path: '/about',
        name: 'About',
        component: () => import('../views/About.vue')
    },
    {
        path: '/login',
        name: 'Login',
        component: () => import('../views/Login.vue')
    }


]


const router = createRouter({

    history: createWebHistory('/'),
    routes: routes

})


export default router
